# coding=utf8
import falcon

from controller.resource.ads import AdsResource, AdContentResource, BandAdResource
from controller.resource.list import ListResource
from controller.resource.news import NewsResource, NewsContentResource, NewsRemoteResource
from controller.user.status import StatusResource
from controller.user.wx import WxResource, WxAccountResource

app = falcon.API()

app.add_route('/ads/classify/{cid}', AdsResource())
app.add_route('/ad/classify/{cid}/content/{aid}', AdContentResource())
app.add_route('/ad/appid/{appid}', BandAdResource())

app.add_route('/get_list', ListResource())

app.add_route('/news/{cid}', NewsResource())
app.add_route('/news/wx/{appid}', NewsRemoteResource())
app.add_route('/news/content/{aid}', NewsContentResource())

app.add_route('/user/status', StatusResource())
app.add_route('/user/wx', WxResource())
app.add_route('/user/wx/{n}', WxAccountResource())
